home *** CD-ROM | disk | FTP | other *** search
/ MacHack 2000 / MacHack 2000.toast / pc / The Hacks / Genie / Projects / V3DDemo / Source / Sources / V3DHandlerOpenDoc.cc < prev    next >
Encoding:
C/C++ Source or Header  |  2000-06-24  |  693 b   |  37 lines

  1. /*    ====================
  2.  *    V3DHandlerOpenDoc.cc
  3.  *    ====================
  4.  */
  5.  
  6. #include <stdio.h>
  7.  
  8. #include "PedestalDebugging.h"
  9. #include "SiesString.hh"
  10. #include "PedFSRef.hh"
  11. #include "V3DAgentDoc.hh"
  12. #include "V3DHandlerOpenDoc.hh"
  13. #include "V3DDocModel.hh"
  14.  
  15.  
  16. V3DHandlerOpenDoc::V3DHandlerOpenDoc(PedApplication &inApp)
  17. : PedHandlerOpenDoc(inApp)
  18. {
  19. }
  20.  
  21. V3DHandlerOpenDoc::~V3DHandlerOpenDoc()
  22. {
  23. }
  24.  
  25. void
  26. V3DHandlerOpenDoc::DoOpenDoc(FSSpec &inFSS)
  27. {
  28.     PedFSRef *ref = new PedFSRef(inFSS);
  29.     ref->autorelease();
  30.     V3DDocModel *doc = new V3DDocModel;
  31.     V3DAgentDoc *agent = new V3DAgentDoc((PedTask *)&mApp, doc);
  32.     doc->release();
  33.     agent->autorelease();
  34.     doc->SetFile(*ref);
  35.     agent->OpenWindow();
  36. }
  37.